// The Vue build version to load with the `import` command
// (runtime-only or standalone) has been set in webpack.base.conf with an alias.
import Vue from 'vue'
import App from './App'
import vueRouter from 'vue-router'
import vueResource from 'vue-resource'

Vue.use(vueResource)
Vue.use(vueRouter)

Vue.config.productionTip = false

import template1 from './components/template1.vue'
import template2 from './components/template2.vue'
import template3 from './components/template3.vue'

const routes = [
    { path: '/', redirect: '/template1'}, 
    { path: '/template1', component: template1 },
    { path: '/template2', component: template2 },
    { path: '/template3', component: template3 }
]

const router = new vueRouter({
  routes
})

new Vue({
  el: '#app',
  template: '<App/>',
  components: { App },
  router
});